package com.lala.commom.remote;

import com.github.pagehelper.PageInfo;
import com.lala.commom.pojo.Teacher;
import org.springframework.web.bind.annotation.RequestBody;
import org.springframework.web.bind.annotation.RequestMapping;
import org.springframework.web.bind.annotation.RequestParam;

import java.util.List;

public interface TeacherRemote {
    /*分页查询*/
    @RequestMapping("/selectTeacher")
    PageInfo<Teacher> selectTeacher(@RequestParam("p") int p, @RequestParam("s") int s);

    /*特定查询*/
    @RequestMapping("/selectByPrimaryKey")
    List<Teacher> selectByPrimaryKey(@RequestParam("id") Integer id);

    /*(修改)审核是否通过 0通过*/
    @RequestMapping("/updateTeacherTy")
    int updateTeacherTy(@RequestParam("id") Integer id);

    /*(修改)审核是否通过 1未通过*/
    @RequestMapping("/updateTeacherBty")
    int updateTeacherBty(@RequestParam("id") Integer id);

    //分页查询所有审核通过的教师
    @RequestMapping("/selectTeacher1")
    PageInfo<Teacher> selectTeacher1(@RequestParam("pageNum") int pageNum, @RequestParam("pageSize") int pageSize);

    @RequestMapping("/updateType")
    int updateType(@RequestBody Teacher teacher);

    /*解约教师*/
    @RequestMapping("/deleteTeacher")
    int deleteTeacher(@RequestParam("id") Integer id);

    @RequestMapping("/shenqing")
    int shenqing(@RequestBody Teacher teacher);

}
